<!DOCTYPE html>
<html lang="en">

<head>
    <title></title>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <script>
       function* demo() {
         
            console.log('Hello' )// OK
            yield 
            console.log(y)
      
        }

        let aa =demo()
        console.log(aa.next('aa'))
        console.log(aa.next())
        // console.log(aa.next())
    </script>
</head>

<body>



</body>

</html>